import request from '../../utils/Request'

export const saveDict = data => {
  return request({
    method: 'post',
    url: '/api/manage/dict/save',
    data: data
  })
}
export const createDict = data => {
  return request({
    method: 'post',
    url: '/api/manage/dict/create',
    data: data
  })
}
export const updateDict = data => {
  return request({
    method: 'post',
    url: '/api/manage/dict/update',
    data: data
  })
}
export const updateDictStatus = (dictId, status) => {
  return request({
    method: 'get',
    url: '/api/manage/dict/' + dictId + '/status/' + status,
    params: {}
  })
}

export const selectDictByCode = dictCode => {
  return request({
    method: 'get',
    url: '/api/manage/dict/select/code/' + dictCode,
    params: {}
  })
}

export const deleteDict = bId => {
  return request({
    method: 'get',
    url: '/api/manage/dict/delete/' + bId,
    params: {}
  })
}

export const listDict = data => {
  return request({
    method: 'get',
    url: '/api/manage/dict/list',
    params: data
  })
}

export const mapDict = () => {
  return request({
    method: 'get',
    url: '/api/manage/dict/map',
    params: {}
  })
}





